Respiration monitor

ABSTRACT

A system for respiration monitoring includes a garment, which is configured to be fitted snugly around a body of a human subject, and which includes, on at least a portion of the garment that fits around a thorax of the subject, a pattern of light and dark pigments having a high contrast at a near infrared wavelength. A camera head is configured to be mounted in proximity to a bed in which the subject is to be placed, and includes an image sensor and an infrared illumination source, which is configured to illuminate the bed with radiation at the near infrared wavelength, and is configured to transmit a video stream of images of the subject in the bed captured by the image sensor to a processor, which analyzes movement of the pattern in the images in order to detect a respiratory motion of the thorax.

CROSS-REFERENCE TO RELATED APPLICATION

This application is a continuation of U.S. patent application Ser. No. 16/197,479, filed Nov. 21, 2018, which claims the benefit of U.S. Provisional Patent Application 62/589,587, filed Nov. 22, 2017, which is incorporated herein by reference.

FIELD OF THE INVENTION

The present invention relates generally to sleep monitoring, and particularly to apparatus, systems and methods for video-based monitoring of a sleeping infant.

BACKGROUND

Video-based sleep monitors for infants are known in the art. For example, U.S. Pat. No. 8,922,653 describes a crib mobile and surveillance system which communicates video data captured by a camera within a mobile member housing, and sounds received by a microphone disposed in a base, to a handheld monitor. The video data are displayed and broadcast in real time on a monitor screen on the handheld monitor to remotely monitor a child lain in a crib having the present device.

U.S. Pat. No. 9,530,080, whose disclosure is incorporated herein by reference, describes systems and methods for monitoring babies with cameras using a centralized computation and storage center that allows using visual output signals for computer vision and machine learning analysis and high-level reasoning of baby movements. The system comprises a camera located at a predefined working point above a baby's crib, and one or more communication networks between components of the system including a web-based network for in-depth computer vision and machine learning analysis of the visual output signals by an analysis server.

PCT International Publication WO 2017/196695, whose disclosure is incorporated herein by reference, describes a video monitoring system, which includes a camera head, including an infrared illumination source and an image sensor. A mount is configured to hold the camera head in a fixed location and orientation above a crib, so that the image sensor captures images of the crib and an intervention region adjacent to the crib from a fixed perspective.

As another example, U.S. Patent Application Publication 2013/0342693 describes a video-enabled baby monitoring system including a transmitter with a camera feature, which captures motion and includes microprocessors that generate a series of video signal codes, which are transmitted at specific radio frequencies to a dedicated receiver unit. The transmitter unit also includes an infrared light source and a sound capture source, wherein the sound capture source generates sound signal codes. Another unit provides for enhanced, convenient data transfer from the transmitter unit and may be selected from a number of adaptor docking stations; or a smart phone platform; or a docking cradle with Wi-Fi capability.

Systems for monitoring the breathing of a sleeping person are also known in the art. For example, U.S. Patent Application Publication 2004/0005083 describes a method and system for monitoring breathing movement of an infant and for detecting and predictably estimating regular cycles of breathing movements. Another disclosed aspect of the invention is directed to detect and report irregularity of breathing activity of an infant, such as cessation and non-periodicity, which suggests a likelihood of SIDS.

U.S. Patent Application Publication 2015/0105670 relates measurement of vital signs such as a respiratory rate or a heart rate. In particular, a system for determining a vital sign of a subject comprises an imaging unit for obtaining video data of the subject, a marker directly or indirectly attached to a body of the subject, wherein the marker comprises a graphical pattern, an image processing unit for detecting said marker in said video data, and an analysis unit adapted to extract a vital sign parameter related to the vital sign of the subject from said video data and to determine the vital sign from said vital sign parameter.

U.S. Patent Application Publication 2016/0345832 describes a system and method for monitoring biological status through contactless sensing that includes a sensing device with at least one video imaging device; a sensor data processing unit, wherein the sensor processing unit when in a respiratory sensing mode is configured to extract a set of primary components of motion from image data from the video imaging device; a biological signal processor that when in a respiratory sensing mode is configured to identify at least one dominant component of motion and generate a respiratory signal; and a monitor system.

SUMMARY

Embodiments of the present invention that are described hereinbelow provide systems and methods for monitoring respiration of a sleeping infant or other human subject.

There is therefore provided, in accordance with an embodiment of the invention, a system for respiration monitoring, including a garment, which is configured to be fitted snugly around a body of a human subject, and which includes, on at least a portion of the garment that fits around a thorax of the subject, a pattern of light and dark pigments having a high contrast at a near infrared wavelength. A camera head is configured to be mounted in proximity to a bed in which the subject is to be placed, and includes an image sensor and an infrared illumination source, which is configured to illuminate the bed with radiation at the near infrared wavelength, and is configured to transmit a video stream of images of the subject in the bed captured by the image sensor to a processor, which analyzes movement of the pattern in the images in order to detect a respiratory motion of the thorax.

In some embodiments, the human subject is an infant, the bed is a crib, and the garment includes a swaddling cloth. In one embodiment, the swaddling cloth is configured as a sack, having a size and shape suitable for containing the body of the infant. Alternatively, the swaddling cloth is configured as a band, having a size and shape suitable to surround the thorax of the infant.

In a disclosed embodiment, the pattern extends around both a front and a back of the thorax when the garment is fitted around the body of the subject.

In some embodiments, the pattern includes an arrangement of light or dark geometrical shapes, which repeat across at least the portion of the garment, and the processor is configured to identify and track the geometrical shapes in the images in order to analyze the movement. In a disclosed embodiment, the shapes have respective corners, and the processor is configured to identify and track the corners in the images in order to analyze the movement.

Additionally or alternatively, the processor is configured to calibrate a scale of the images responsively to a distance between the repeating shapes. In one embodiment, the processor is configured to apply the scale in measuring the respiratory motion. Additionally or alternatively, the processor is configured to apply the scale in measuring one or more dimensions of the subject.

In a disclosed embodiment, the processor is configured to identify, responsively to the movement of the pattern, a deviation of at least one of an amplitude and a rate of the respiratory motion from a predefined normal range, and to issue an alert in response to the deviation.

There is also provided, in accordance with an embodiment of the invention, a method for respiration monitoring, which includes providing a garment, which is configured to be fitted snugly around a body of a human subject, and which includes, on at least a portion of the garment that fits around a thorax of the subject, a pattern of light and dark pigments having a high contrast at a near infrared wavelength. A bed in which the subject is placed is illuminated with radiation at the near infrared wavelength. A video stream of images of the subject in the bed is captured while illuminating the bed at the near infrared wavelength. Movement of the pattern in the images is analyzed in order to detect a respiratory motion of the thorax.

The present invention will be more fully understood from the following detailed description of the embodiments thereof, taken together with the drawings in which:

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 is a block diagram that schematically illustrates a system for infant sleep monitoring, in accordance with an embodiment of the invention;

FIG. 2 is a schematic top view of a sleep monitoring device mounted over an infant's crib, in accordance with an embodiment of the invention;

FIGS. 3A and 3B are schematic front and back views, respectively, of a swaddling sack used in monitoring respiration of an infant, in accordance with an embodiment of the invention;

FIGS. 4A and 4B are schematic outer and inner views, respectively of a swaddling band used in monitoring respiration of an infant, in accordance with another embodiment of the invention; and

FIG. 5 is a flow chart that schematically illustrates a method for respiration monitoring, in accordance with an embodiment of the invention.

DETAILED DESCRIPTION OF EMBODIMENTS Overview

Concern over proper respiration leads many parents of young infants to monitor their child's nighttime breathing. A wide range of product offerings exist for this purpose, but they tend to be uncomfortable, unreliable, or both.

Embodiments of the present invention that are described herein offer a new solution to the problem of infant respiration monitoring, using a novel garment, which facilitates both reliable detection of respiratory motion and infant comfort, while fitting snugly around the infant's body. (“Snug” in this context means that the garment fits tightly enough so that the cloth will expand and contract as the infant's thorax expands and contracts in respiration, without being so tight as to constrict respiratory motion.)

Substantially any suitable type of garment can be used for the present purposes. By way of example, the embodiments described below refer specifically to a swaddling cloth, such as a swaddling sack, having a size and shape suitable for containing the entire body of the infant, or a swaddling band, which fits around the thorax. The use of a swaddling cloth is advantageous in promoting both sound sleep and reliable monitoring. The principles of the present invention, however, are by no means limited to this type of garment, and may alternatively be applied in monitoring the respiration of other subjects, including older children, as well as adults.

Regardless of the specific configuration, the garment comprises a pattern of light and dark pigments on at least a portion of the garment that fits around the thorax of the subject. The light and dark pigments are chosen so that the pattern has a high contrast at a near infrared (NIR) wavelength, meaning specifically a wavelength between 800 nm and 1500 nm. This wavelength range is useful due to the availability of intense, inexpensive solid-state light sources, such as light-emitting diodes (LEDs), and the sensitivity of common image sensors in this range, while being invisible to human eyes. The terms “light” and “dark” in relation to the pigments mean, in the context of the present description and in the claims, that the “light” pigment reflects at least 50% of the incident radiation at a chosen illumination wavelength in the NIR, while the “dark” pigment reflects less than 20% of the incident light at this wavelength. The term “high contrast” in this context means that when the pattern is illuminated uniformly at the chosen wavelength, the intensity of reflected light received by the image sensor from the light pigment is at least twice that received from the dark pigment.

In the disclosed embodiments, a camera head is mounted in proximity to a bed in which the subject is to be placed. The camera comprises an image sensor and an infrared illumination source, which illuminates the crib at a chosen wavelength in the NIR. The image sensor captures images of the subject in the bed (for example, of an infant in a crib, as shown in the figures that are described below). The camera head transmits a video stream of these images to a processor, which analyzes movement of the pattern in the images in order to detect the respiratory motion of the thorax. When the processor detects a deviation of the amplitude and/or rate of the respiratory motion from a predefined normal range, it issues an alert and thus enables a caregiver to intervene immediately. The garment can be designed so that the pattern extends around both the front and the back of the thorax; the respiratory motion can thus monitored reliably regardless of whether the subject is lying on his or her front, back or side. Alternatively, the pattern may appear only the front of the thorax.

In some embodiments, the pattern comprises an arrangement of light or dark geometrical shapes, which repeat periodically across at least the portion of the garment that extends across the thorax. This sort of pattern facilitates fast and accurate processing of the images by the processor. For example, the processor can identify corners of the geometrical shapes and track these corners in the images in order to analyze the movement of the pattern.

When the actual, physical sizes of the shapes on the swaddling cloth are known, the processor can calibrate the scale of the images based on the distance (in pixels) between the repeating shapes in the images, and can then apply this scale in measuring the respiratory motion and/or measuring one or more dimensions of the subject. These latter measurements include, but are not limited to, the distance an infant being monitored traveled in a crib, the distance crawled, the magnitude of head movements, the magnitude of limb movements, the magnitude of twitches, head circumference, head shape, head volume, height, body volume, weight and BMI estimations, limb length, distance between the eyes, forehead height, general facial dimensions, shoulder width, hip width, hip angles, foot angles, torso length. The calibrated scale can also be used to improve object detection algorithms by normalizing the image size to minimize the size tolerance of detection of objects such as the crib, the infant, and its head.

Although the figures and the embodiments described below refer to certain specific swaddling cloth designs, with a certain pattern shown by way of example, other sorts of garments and other patterns that can be used for the present purposes will be apparent to those skilled in the art after reading the present description. All such alternative embodiments are considered to be within the scope of the present invention.

System Description

FIG. 1 is a block diagram that schematically illustrates a system 20 for infant sleep monitoring, in accordance with an embodiment of the invention. System 20 comprises a monitoring camera head 22, which is mounted in a fixed location and orientation above a crib 24, in which an infant 26 is sleeping in a residence 28. Alternatively, camera head 22 may be mounted in another suitable location in proximity to the crib, mounted on a wall or tabletop, for example.

For purposes of image capture, an infrared (IR) light-emitting diode (LED) 25 on the lower side of camera head 22 illuminates the sleeping infant 26. A diffuser can be used to spread the infrared light uniformly across the crib. Camera head 22 also comprises an infrared-sensitive image sensor 23, which may conveniently have a standard 4:3 aspect ratio to fit the size of a standard crib 24. The resolution and sensitivity of image sensor 23 can be optimized for night conditions, and specifically for the wavelength range of LED 25. Further details of camera head 22, including its internal components and modes of operation, are described in the above-mentioned PCT International Publication WO 2017/196695 (particularly in FIGS. 4A/B and 5 and the corresponding description in the specification on pages 8-9). This PCT publication also describes different ways of mounting the camera head above or alongside the crib.

Camera head 22 transmits digitized streaming video, and possibly other signals, as well, over a local network to a router 30, typically via a wireless local area network (LAN) link, such as a Wi-Fi connection, or a wired link, such as an Ethernet connection. Camera head 22 transmits the digitized video data in packets that are addressed so that router 30 forwards the video packets both to a local client device 32 on the local network and via a public network 36, such as the Internet, to a remote server 38. Client device 32 typically comprises a smart phone, tablet or personal computer, which enables a caregiver 34 in another room of residence 28 to monitor infant 26, even when there is no Internet connection available. Server 38 makes video images and other data available to authorized remote client devices 44, thus enabling a caregiver 46 to monitor infant 26 at any location where there is access to public network 36. The Wi-Fi or other local network connection provides reliable video streaming from camera head 22 to client device 32 with high bandwidth and low latency, even if the external Internet connection is not working. As long as the Internet is connected, however, the video stream is also transmitted to server 38 for purposes of analysis and retransmission.

Server 38 typically comprises a general-purpose computer, comprising a processor 40 and a memory 42, which receives, stores and analyzes images from camera head 22 in residence 28 and similarly from other cameras in other residences (not shown). In the present embodiment, processor 40 analyzes the images in order to detect and measure respiratory motion of the thorax of infant 26, and to provides caregivers 34 and 46 with reports and (when required) alerts regarding the infant's breathing patterns. Processor 40 typically performs these functions under the control of software, which may be downloaded to server 38 in electronic form, over a network, for example, as well as stored on tangible, non-transitory computer-readable media, such as magnetic, optical or electronic memory media. Alternatively or additionally, some or all of these processing and monitoring functions may be performed locally, for example by a microprocessor in camera head 22 and/or by suitable application software running on processors in client devices 32 and/or 44.

FIG. 2 is a schematic top view showing details of the deployment and use of monitoring camera head 22 over crib 24, in accordance with an embodiment of the invention. Infant 26 in crib 24 is wrapped in a swaddling sack 52, with a periodic pattern printed on a portion 54 of the swaddling sack that fits around the infant's thorax. In this embodiment, monitoring camera head 22 stands against a wall over crib 24. Camera head 22 is held, for example, at the end of an arm at the upper end of a tripod mount behind crib 24, at the midpoint of the long side of the crib. Camera head 22 in this embodiment is positioned and adjusted so that the camera head has a field of view 50 from a fixed perspective that encompasses at least the area of crib 24. This perspective provides server 38 with image information that can be analyzed conveniently and reliably to detect respiratory motion of infant 26. Alternatively, the camera head may be mounted in any other suitable location in proximity to crib 24 that gives a view of the infant that is suitable for monitoring movement of the pattern on the swaddling cloth or other garment.

FIGS. 3A and 3B are schematic front and back views, respectively, of swaddling sack 52, which is used in monitoring the respiration of infant 26, in accordance with an embodiment of the invention. Before putting infant 26 into crib 24, the caregiver inserts the infant into swaddling sack 52, and then fastens a band 58 snugly around the infant's thorax. Hook and loop patches 60 and 62 (such as Velcro® patches) may be used for this purposes, or any other suitable type of fastener that is known in the art.

Portion 54 of swaddling sack 52 comprises a periodic pattern of light and dark pigments, extending around both the front and back of sack 52, with a high contrast at the near infrared wavelength of LED 25. In this example, the pattern comprises two types of dark geometrical shapes 56, but alternatively other patterns may be used, with one or more different shapes, in either dark or light pigment. The sharp corners of the shapes in this example facilitate detection and tracking of the shapes by an image processor for the purpose of detecting respiratory motion. The dimensions of shapes 56 are typically between 5 and 50 mm, and camera head is designed so that each shape will have an extent between 3 and 30 pixels in the images captured by image sensor 23, although larger or smaller shapes and magnifications may alternatively be used.

FIGS. 4A and 4B are schematic outer and inner views, respectively, of a swaddling band 70 used in monitoring respiration of an infant, in accordance with another embodiment of the invention. The size and shape of band 70 are suitable to surround the thorax of an infant, with the band fastened snugly around the thorax by hook and loop patches 72 and 74. Band 70 leaves the infant free to move his or her arms and legs, in contrast to sack 52. The pattern of shapes 56 on band 70 is similar to that on sack 52, as described above.

Monitoring of Respiratory Motion

FIG. 5 is a flow chart that schematically illustrates a method for respiration monitoring, in accordance with an embodiment of the invention. This method is described hereinbelow, for the sake of concreteness and clarity, with reference to the elements of system 20 and swaddling sack 52, as shown and described above. Alternatively, the method may be applied, mutatis mutandis, in other system configurations and/or using other sorts of swaddling cloth, as noted earlier. Specifically although certain image processing functions and communication functions are described below as being carried out by server 38, at least some of these functions may be carried out by other means, such as client devices 32 and 44 and/or a processor (not shown) that is embedded in camera head 22.

Processor 40 initiates the method of FIG. 5 upon receiving a video stream from camera head 22 and a signal (for example from the camera head or from client device 32) indicating that monitoring is to begin. Processor 40 finds a region of interest (ROI) that contains a part of the pattern on swaddling sack 52 in an initial image frame, at an ROI identification step 80. The ROI may be identified automatically by analyzing the image to locate the pattern on swaddling sack 52 (or swaddling band 70, for example). Processor 40 may access features of the pattern or patterns that are used on various types of swaddling cloth, such as the sizes and forms of shapes 56, in memory 42, in order to identify the ROI more easily. Alternatively or additionally, the caregiver may indicate the location of the ROI to the processor, for example by pointing to the ROI in an image from camera head 22 that is displayed on client device 32.

In some embodiments, processor 40 finds the locations of the corners of shapes 56 in the ROI on swaddling sack 52, at a corner finding step 82. (“Corners” are not necessarily right angles, and can be formed that the meeting point of edges at different angles, for example angles ranging between 60° and 120°.) Corners can be found by filtering the part of the image that is contained in the ROI with filters that are matched to the geometrical features of the pattern, for example. Once the corners are found, processor 40 can calibrate the scale of the images by comparing the distance between the repeating shapes in the images to the known distance between the geometrical features on the swaddling sack.

Once the ROI and pattern features have been identified in the initial image, processor 40 receives and processes succeeding images in the video stream, at an image input step 84. In each image, the processor tracks the movement of each of the corners in the ROI that was identified previously. This step may use techniques such as feature mapping or the Kanade-Lucas-Tomasi (KLT) feature tracking algorithm in order to measure motion from frame to frame with sub-pixel accuracy. If the ROI is lost in a given image or sequence of images, for example due to large movements of infant 26, processor 40 may search over an entire image in order to recover the location of the ROI and may then return to step 80.

Alternatively or additionally, processor 40 may apply other sorts of image processing algorithms in identifying and tracking movement of the pattern, not necessarily depending on corners. For example, template shift registration can be used to track shapes having no clear corners (such as circles). As another example, normal flow algorithms can be used in tracking object edges.

Since respiratory movement from one frame to the next is very small, processor 40 averages the motion of each corner (or other feature) over multiple successive frames and/or multiple feature locations, at a movement averaging step 88. When infant 26 is breathing, the infant's thorax expands and contracts periodically, so that all of the corners within a given ROI on swaddling sack 52 will move in the same direction from frame to frame, with a temporal variation that is approximately sinusoidal. The average movement will therefore be substantial. (The ROI is chosen at step 80 to be large enough to contain multiple shapes 56, but small enough so that all the shapes in the ROI move in the same direction during respiration.) On the other hand, when infant 26 is not breathing, the directions of movement of the different corners will be random and will thus cancel out upon averaging. Processor 40 may also identify large movements that are not periodic as corresponding to the infant moving in his or her sleep or being awake.

Processor 40 analyzes the averaged movement signal over time in order to detect periodic motion that is characteristic of respiration, at a movement analysis step 90. For this purpose, processor 40 may filter the averaged signal using a set of bandpass filters with frequency bands distributed through the range of normal respiration frequencies. For example, processor 40 may apply a set of six bandpass filters that together span the normal breathing range, which is about 20-60 breaths/minute for infants under one year old. Any suitable type of bandpass filter with sufficiently sharp edges may be used for this purpose, for instance a fifth-order Butterworth filter, as is known in the art. Alternatively, larger or smaller numbers of filters, of this or other types, may be used, depending upon the available computing power and the level of precision that is required to avoid false alarms.

After filtering the signal at step 90, processor 40 chooses the frequency band with the highest amplitude, at a band selection step 92. Processor 40 compares this amplitude to a preset threshold, at a motion checking step 94. If the amplitude is below threshold, and remains below threshold for longer than a preset time limit, processor 40 issues an alert, at an alarm step 96. Infants may normally stop breathing for short periods, typically up to 20 sec, and then resume breathing normally. The time limit at step 94 may thus be set, for example, to 20 sec. If processor 40 does not detect respiratory motion of sufficient amplitude over a period longer than this limit, it may send a notification to client device 32 at step 96, for instance, or take more drastic action, such as triggering a visible and/or audible alarm in residence 28. For example, processor 40 may activate a visible light and/or audio speaker in camera head 22.

When processor 40 detects respiratory motion of sufficient amplitude at step 94, it also checks the infant's respiratory frequency, at a rate checking step 98. If the highest motion amplitude was found to be in the highest or lowest frequency band of the filters applied at step 92, for example, the processor may conclude that the breathing rate is abnormally high or low. In this case, too, processor 40 will issue an alert at step 96. Otherwise, the processor concludes that the infant's breathing is normal and continues to capture and analyze further images as described above. Optionally, processor 40 may continually issue updates to client devices 32 and 44, even when infant 26 is breathing normally, to indicate the breathing status and respiratory rate of the infant.

As noted earlier, although the embodiments described above relate specifically to infant respiration monitoring, using a patterned swaddling cloth, the principles of the present invention may similarly be applied using other sorts of garments with suitable pattern, not only for infants but also for older subjects. It will thus be appreciated that the embodiments described above are cited by way of example, and that the present invention is not limited to what has been particularly shown and described hereinabove. Rather, the scope of the present invention includes both combinations and subcombinations of the various features described hereinabove, as well as variations and modifications thereof which would occur to persons skilled in the art upon reading the foregoing description and which are not disclosed in the prior art. 

1. A system for respiration monitoring, comprising: a garment, having a size and shape suitable to surround and fit snugly around a body of a sleeping infant, and which comprises, on at least a portion of the garment that fits around a thorax of the subject, a pattern of light and dark pigments having a high contrast at a near infrared wavelength; and a camera head, which is configured to be mounted in proximity to a bed in which the infant is to be placed, and which comprises an image sensor and an infrared illumination source, which is configured to illuminate the bed with radiation at the near infrared wavelength, and which is configured to transmit a video stream of images of the subject in the bed captured by the image sensor to a processor, which analyzes movement of the pattern in the images in order to detect a respiratory motion of the thorax.
 2. The system according to claim 1, wherein the pattern extends around a front, a back and sides of the thorax when the garment is fitted around the body of the infant, whereby the processor is able to detect the respiratory motion of the thorax regardless of whether the infant is lying on his or her front, back or side.
 3. The system according to claim 1, wherein the garment is configured as a sack, having a size and shape suitable for containing the body of the infant.
 4. The system according to claim 1, wherein the pattern comprises an arrangement of light or dark geometrical shapes, which repeat across at least the portion of the garment, and wherein the processor is configured to identify and track the geometrical shapes in the images in order to analyze the movement.
 5. The system according to claim 4, wherein the shapes have respective corners, and wherein the processor is configured to identify and track the corners in the images in order to analyze the movement.
 6. The system accordingly to claim 4, wherein the processor is configured to calibrate a scale of the images responsively to a distance between the repeating shapes.
 7. The system according to claim 6, wherein the processor is configured to apply the scale in measuring the respiratory motion.
 8. The system according to claim 6, wherein the processor is configured to apply the scale in measuring one or more dimensions of the infant.
 9. The system according to claim 1, wherein the processor is configured to identify, responsively to the movement of the pattern, a deviation of at least one of an amplitude and a rate of the respiratory motion from a predefined normal range, and to issue an alert in response to the deviation.
 10. A method for respiration monitoring, comprising: providing a garment, having a size and shape suitable to surround and fit snugly around a body of a sleeping infant, and which comprises, on at least a portion of the garment that fits around a thorax of the subject, a pattern of light and dark pigments having a high contrast at a near infrared wavelength; and illuminating a bed in which the infant is placed with radiation at the near infrared wavelength; capturing a video stream of images of the subject in the bed while illuminating the bed at the near infrared wavelength; and analyzing movement of the pattern in the images in order to detect a respiratory motion of the thorax.
 11. The method according to claim 10, wherein the pattern extends around a front, a back and sides of the thorax when the garment is fitted around the body of the infant, whereby analyzing the movement comprises detecting the respiratory motion of the thorax regardless of whether the infant is lying on his or her front, back or side.
 12. The method according to claim 10, wherein the garment is configured as a sack, having a size and shape suitable for containing the body of the infant.
 13. The method according to claim 10, wherein the pattern comprises an arrangement of light or dark geometrical shapes, which repeat across at least the portion of the swaddling garment, and wherein analyzing the movement comprises identifying and tracking the geometrical shapes in the images.
 14. The method according to claim 13, wherein the shapes have respective corners, and wherein identifying and tracking the geometrical shapes comprises identifying and tracking the corners in the images.
 15. The method accordingly to claim 13, wherein identifying and tracking the geometrical shapes comprises calibrating a scale of the images responsively to a distance between the repeating shapes.
 16. The method according to claim 15, wherein analyzing the movement comprises applying the scale in measuring the respiratory motion.
 17. The method according to claim 15, and comprising applying the scale in measuring one or more dimensions of the infant.
 18. The method according to claim 10, wherein analyzing the movement comprises identifying, responsively to the movement of the pattern, a deviation of at least one of an amplitude and a rate of the respiratory motion from a predefined normal range, and issuing an alert in response to the deviation. 